import axios from 'axios'
import store from 'store2'
import qs from 'qs'
const apiURL='http://47.101.39.204:3000'
const imgURL='http://47.101.39.204:3000'
axios.defaults.baseURL=apiURL
axios.defaults.withCredentials=true//解决cookie跨域问题
axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded';
axios.defaults.transformRequest=function(data,header){
    return qs.stringify(data)
}

export default{
    install(Vue,options){
        Vue.prototype.apiURL=apiURL;
        Vue.prototype.imgURL=imgURL;
        Vue.prototype.axios=axios;
        Vue.prototype.store=store;

    }
}